﻿using NewLife.Data;

namespace newlife.core.api.Models
{
    /// <summary>
    /// Core 雪花单例类
    /// </summary>
    public class CoreSnowflakeSingleton
    {
        // 仅在首次访问时会 new 一下
        private static readonly Snowflake _snowflake = new();

        public static long GetId() => _snowflake.NewId();
    }
}
